package com.source.multithread.controller;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.text.SimpleDateFormat;
import java.util.Date;

/**
 * @Author wengqy
 * @Date 2020/12/25
 */
@RestController
public class LoginController {
    @Value("${server.port}")
    private Integer port;
    @RequestMapping({"/","/login"})
    public String login(){
        return "login successful   port:  "+port+"---"+"   Time: "+new SimpleDateFormat("yyyy-MM-dd HH:mm:ss.SSS").format(new Date());
    }
}
